<?php
/**
 * Created by PhpStorm.
 * User: server
 * Date: 2018/12/7
 * Time: 11:21
 */

namespace app\homepage\controller;

use app\common\controller\Base;

/**
 * @title 首页（模块07-01）
 * @description 用户信息说明
 * @group 首页（07）
 * @header name:model_id require:0 default:01-01 desc:模块
 */
class Homepage extends Base
{
    /**
     * @title 前台首页
     * @description 前台首页
     * @author 李锐志
     * @url /homepage/homepage/index
     * @method *
     */
    public function index()
    {
        $result['roll_notice'] = get_curl('announcement','/roll_notice/get_roll_notice')['list'];
        $result['banner'] = get_curl('banner','/banner/get_banner')['list']['data'];
        $result['notice'] = get_curl('announcement','/notice/get_notice')['list']['data'];
        $result['topic_category'] = get_curl('topic','/topic_category/homepage_topic_category')['list'];
        $result['stylist'] = get_curl('user','/user/homepage_stylist')['list'];
        $result['psychologist'] = get_curl('user','/user/homepage_psychologist')['list'];
//        $result['config'] = get_curl('system','/config/get_config')['data'];
//        $result['friendly_link'] = get_curl('system','/friendly_link/get_friendly_link')['data'];
        $msg['msg'] = '首页内容获取成功';
        $msg['data'] = $result;
        return $this->successJson($msg);
    }
}